Shah Rukh had backed his Kolkata Knight Riders' coach John Buchanan's multiple captain idea and had criticised Gavaskar for his remarks against the Australian's coaching method.
And Miandad, paying tribute to Gavaskar on the occasion of his 60th birthday, wondered if the legendary batsman was yet to win the respect of his "rich and famous" compatriots despite his contributions to the country.
"It happened before the Indian Premier League-2 got under way in South Africa, but it still rankles me. I simply cannot tolerate the insult Shah Rukh Khan heaped on our icon, " Miandad wrote in a book compiled by veteran journalist Debashish Dutta.
"Even my fellow cricketers in Pakistan were shocked... by Shah Rukh's verbal volleys. It is sad that despite achieving so much for his country Sunil Gavaskar is yet to earn the respect of rich and famous, " he said.
"I know that these days money talks but, believe me, no amount of money can produce another Gavaskar. By insulting Sunny, Shah Rukh has indirectly insulted us, too, " he added.
Miandad, who has had three stints as coach of Pakistan team, also advised Shah Rukh to learn some sportsman spirit from Gavaskar.
"Sunny is a gentleman and it is his greatness that he ignored Shah Rukh's comments. It only showed how spirited a man Sunny is. Shah Rukh should learn from Sunil, " he said.
Another Pakistan great Wasim Akram rued that despite his 400 wickets in both Tests and ODIs, he could not find success against Gavaskar.
"When I look back on my long playing career, I feel quite happy and satisfied. However, I have just one minor regret - I could not dismiss Sunil Gavaskar even once in Test matches.
"I have claimed Gavaskar's wicket just once in my career. It was in an ODI in Hyderabad on our tour of India in 1986-87, " he wrote.
Former Pakistan tearaway and captain Imran Khan believes Gavaskar's greatness "lay in the fact that he knew his limitations".
"His only flaw was against the quick bowlers bowling into his body when his lack of height would get him rather tucked up. He would sometimes be in trouble on wickets of uneven bounce because he didn't hook and was loath to dick or leave the ball because unpredictability of the bounce; apart from that a masterful batsman with a great temperament, " said Imran.